home *** CD-ROM | disk | FTP | other *** search
AMOS Source Code | 1993-02-25 | 1.1 KB | 47 lines |
- Rem example10_1.amos
- '
- '
- Rem display a bob 1 from a loaded sprite file
- '
- '
- Rem the usual stuff, not forgetting FLASH OFF, try it without it!
- Flash Off : Curs Off : Paper 0 : Hide : Cls 0
- '
- '
- Rem load in the sprite bank into bank 1
- Load "df0:bobs/spacecraft.abk",1
- '
- '
- Rem use the colours from the sprite bank, try it without this line to see effect
- Get Sprite Palette
- '
- '
- Rem assign an Amal channel to bob 1
- Channel 1 To Bob 1
- '
- '
- Rem Display BOB 1 at 10 pixels across and 100 pixels down the screen
- Rem the 1 on the end is the current bob number in use.
- Bob 1,10,100,1
- '
- '
- Rem set up the animation sequence, images 1 to 4 animate the engine flame
- Rem the 5 is the delay in 50ths of a second between each frame, change the
- Rem 5s to see the animation in slow or faster motion.
- Rem the L at the end tells Amos we want the animation to Loop continuously
- Rem and not just play once, remove the L to see the effect.
- Anim 1,"(1,5)(2,5)(3,5)(4,5)l"
- '
- '
- Rem Tell Amos to start the Animation
- Anim On
- '
- '
- Rem CLEAR the KEYboard buffer of keypresses ans WAIT for a KEY press
- Clear Key : Wait Key
- '
- '
- Rem show you what is happening in the memory banks
- List Bank
- '
- '